/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.restaurant.domain;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author root
 */
@Entity
@Table(name = "currencytype")
@XmlRootElement(name="currencytype")
@NamedQueries({
    @NamedQuery(name = "Currencytype.findAll", query = "SELECT c FROM Currencytype c"),
    @NamedQuery(name = "Currencytype.findByCurrencyTypeID", query = "SELECT c FROM Currencytype c WHERE c.currencyTypeID = :currencyTypeID"),
    @NamedQuery(name = "Currencytype.findByCurrencytypename", query = "SELECT c FROM Currencytype c WHERE c.currencytypename = :currencytypename"),
    @NamedQuery(name = "Currencytype.findByIsdeleted", query = "SELECT c FROM Currencytype c WHERE c.isdeleted = :isdeleted")})
public class Currencytype implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Basic(optional = false)
    @Column(name = "CurrencyTypeID")
    private Long currencyTypeID;
    @Column(name = "currencytypename")
    private String currencytypename;
    @Column(name = "isdeleted")
    private Boolean isdeleted;
    
    public Currencytype() {
    }

    public Currencytype(Long currencyTypeID) {
        this.currencyTypeID = currencyTypeID;
    }

    public Long getCurrencyTypeID() {
        return currencyTypeID;
    }

    public void setCurrencyTypeID(Long currencyTypeID) {
        this.currencyTypeID = currencyTypeID;
    }

    public String getCurrencytypename() {
        return currencytypename;
    }

    public void setCurrencytypename(String currencytypename) {
        this.currencytypename = currencytypename;
    }

    public Boolean getIsdeleted() {
        return isdeleted;
    }

    public void setIsdeleted(Boolean isdeleted) {
        this.isdeleted = isdeleted;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (currencyTypeID != null ? currencyTypeID.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Currencytype)) {
            return false;
        }
        Currencytype other = (Currencytype) object;
        if ((this.currencyTypeID == null && other.currencyTypeID != null) || (this.currencyTypeID != null && !this.currencyTypeID.equals(other.currencyTypeID))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "com.restaurant.domain.Currencytype[currencyTypeID=" + currencyTypeID + "]";
    }

}
